package cn.cttic.base.api.domain.vo;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.Date;

import cn.cttic.common.translation.annotation.Translation;
import cn.cttic.common.translation.constant.TransConstant;
import cn.cttic.base.api.domain.BaseUser;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;


/**
 * 账户信息视图对象 base_user
 *
 * @author Times.Studio
 * @date 2024-09-17
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = BaseUser.class)
public class BaseUserVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     *
     */
    @ExcelProperty(value = "")
    private String id;

    /**
     * 用户类型
     */
    @ExcelProperty(value = "用户类型")
    private String userType;

    /**
     * 账户类型
     */
    @ExcelProperty(value = "账户类型")
    private Integer type;

    /**
     * 账户类型
     */
    @Translation(type = TransConstant.DICT_TYPE_TO_LABEL, mapper = "type", other = "dict_user_account_type")
    private Integer typeName;

    /**
     * 登录名
     */
    @ExcelProperty(value = "登录名")
    private String userName;

    /**
     * 真实姓名
     */
    @ExcelProperty(value = "真实姓名")
    private String realName;

    /**
     * 昵称
     */
    @ExcelProperty(value = "昵称")
    private String nickName;

    /**
     * 身份证号码
     */
    @ExcelProperty(value = "身份证号码")
    private String idCardNo;

    /**
     * email
     */
    @ExcelProperty(value = "email")
    private String email;

    /**
     * 联系电话
     */
    @ExcelProperty(value = "联系电话")
    private String phone;

    /**
     * 性别
     */
    @ExcelProperty(value = "性别")
    private Integer gender;

    @Translation(type = TransConstant.DICT_TYPE_TO_LABEL, mapper = "gender", other = "sys_user_sex")
    private String genderName;

    /**
     * 生日
     */
    @ExcelProperty(value = "生日")
    private LocalDate birthday;

    /**
     * 用户状态
     */
    @ExcelProperty(value = "用户状态")
    private Integer status;

    @Translation(type = TransConstant.DICT_TYPE_TO_LABEL, mapper = "status", other = "dict_person_verify_status")
    private String statusName;

    /**
     * 头像
     */
    @ExcelProperty(value = "头像")
    private String avatar;

    /**
     * 头像Url
     */
    @Translation(type = TransConstant.OSS_ID_TO_URL, mapper = "avatar")
    private String avatarUrl;

    /**
     * 上级用户
     */
    @ExcelProperty(value = "上级用户")
    private String pid;

    /**
     * 是否有子节点
     */
    @ExcelProperty(value = "是否有子节点")
    private Integer hasChild;

    /**
     * 人员信息
     */
    @ExcelProperty(value = "人员信息")
    private String personId;

    /**
     * 所属单位
     */
    @ExcelProperty(value = "所属单位")
    private String companyId;

    private String companyName;

    private String channelName;

    /**
     * 是否首次登录
     */
    @ExcelProperty(value = "是否首次登录")
    private Integer firstLogin;

    @Translation(type = TransConstant.DICT_TYPE_TO_LABEL, mapper = "firstLogin", other = "dict_yes_no")
    private String isFirstLogin;


    /**
     * 是否初始密码
     */
    @ExcelProperty(value = "是否初始密码")
    private Integer initialPassword;

    @Translation(type = TransConstant.DICT_TYPE_TO_LABEL, mapper = "initialPassword", other = "dict_yes_no")
    private String isInitialPassword;


    /**
     * 创建时间
     */
    private LocalDateTime createTime;
}
